package DesignPattern.singleton;
//静态内部类
public class singletonDemo5 {
	private static class singleton{
		private static final singletonDemo5 single=new singletonDemo5();
	}
	private singletonDemo5() {
		System.out.println("This is a new instance!");
	}
	static final singletonDemo5 getInstance() {
		return singleton.single;
	}
}
